package com.itheima.dao;

import com.itheima.domain.User;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @Author itheima
 * @Date 2022/5/3 9:13
 */
public interface UserMapper {
    /**
     * 根据主键查询用户
     *
     * @param id
     * @return
     */
    @Select("select * from user where id=#{id}")
    public User selectById(Long id);

    /**
     * 查询所有用户的列表
     *
     * @return
     */
    public List<User> selectList();
}
